package cn.le.listener;

import cn.le.bean.enums.EnumKafkaTopic;
import cn.le.bean.vo.NettyMsg;
import com.alibaba.fastjson.JSONObject;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.stereotype.Component;

/**
 * 离线消息
 */
@Component
public class ImMsgOfflineListener {

    @KafkaListener(topics = {EnumKafkaTopic.im_off_line})
    public void listen(String nettyMsgJson){
        NettyMsg msg = JSONObject.parseObject(nettyMsgJson,NettyMsg.class);
        //离线处理
    }

}
